﻿@model MvcFront.Models.GroupTemplateEditViewModel
@using Telerik.Web.Mvc.UI
@{
    ViewBag.Title = "Edit";
}

<h2>Редактор</h2>

<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>

@using (Html.BeginForm())
{
    @Html.ValidationSummary(true)
    <fieldset>
        <legend>Шаблон документа</legend>
        
        @Html.HiddenFor(model=>model.ID)
        @Html.HiddenFor(model=>model.UserGroupID)
        @Html.HiddenFor(model=>model.DocTemplateID)
        <div class="editor-label">
            @Html.LabelFor(model => model.Name)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Name)
            @Html.ValidationMessageFor(model => model.Name)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.DateStart)
        </div>
        <div class="editor-field">
            @Html.Telerik().DateTimePickerFor(model => model.DateStart)
            @Html.ValidationMessageFor(model => model.DateStart)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.DateEnd)
        </div>
        <div class="editor-field">
            @Html.Telerik().DateTimePickerFor(model => model.DateEnd)
            @Html.ValidationMessageFor(model => model.DateEnd)
        </div>
        
    </fieldset>


    <p>
        <input type="submit" value="Изменить" />
        @Html.ActionLink("Назад", "Index")
        </p>
    

}